package com.wang.exam.mapper;

import com.wang.exam.pojo.Teacher;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import java.util.List;
import java.util.Map;

@Mapper
@Repository
public interface TeacherMapper {
    //id查询
    List<Teacher> getTeacherById(String teacher_id);
    //分页查询老师的登录信息
    List<Teacher> getTeacherList(@Param("page")int page, @Param("rows")int rows);
    List<Teacher> getTeacher(String keyword);
    //查询老师的总记录
    int getCount();
    //删除选中
    int deleteId(String[] ids);
    //添加教师
    int addTeacher(Teacher teacher);
    //修改教师
    int updateTeacher(@Param("teacher_name")String teacher_name,@Param("teacher_pwd")String teacher_pwd, @Param("teacher_id")String teacher_id);
    //修改教师密码
    int upTeacherPassWord(Map<String,Object> map);
    //删除教师
    int deleteTeacher(String teacher_id);
}

